<%@page import="entities.ListaDePrecios"%>
<%@page import="entities.Rodamiento"%>
<%@page import="java.util.List"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Lista de Precios</title>



	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
   	<title>Integración de Aplicaciones</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">

    <!-- Le styles -->
    <link href="css/bootstrap.css" rel="stylesheet">
    <style type="text/css">
      body {
        padding-top: 60px;
        padding-bottom: 40px;
      }
    </style>
    <link href="css/bootstrap-responsive.css" rel="stylesheet">

 <link rel="shortcut icon" href="http://twitter.github.com/bootstrap/assets/ico/favicon.ico">
    <!-- Fav and touch icons
    <link rel="apple-touch-icon-precomposed" sizes="144x144" href="http://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-144-precomposed.png">
    <link rel="apple-touch-icon-precomposed" sizes="114x114" href="http://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-114-precomposed.png">
    <link rel="apple-touch-icon-precomposed" sizes="72x72" href="http://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-72-precomposed.png">
    <link rel="apple-touch-icon-precomposed" href="http://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-57-precomposed.png"> -->
    <script type="text/javascript" src="js/jquery-1.4.2.min.js" ></script>
  </head>
<body>
<div class="navbar navbar-inverse navbar-fixed-top">
      <div class="navbar-inner">
        <div class="container">
          <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </a>
          <a class="brand" href="index.jsp">Proveedor</a>
          <div class="nav-collapse collapse">
            <ul class="nav">
              <li class="active"><a href="AltaRodamiento">Alta de Rodamientos</a></li>
              <li><a href="ListaPrecios">Lista de precios</a></li>
            </ul>
          </div>
        </div>
      </div>
    </div>
	<div class="container well">
		<div class="page-header" style="font-size: 24px;">Lista de Precios</div>
		<form class="form-horizontal" method="GET" action="ListaDePreciosServlet" name="listaDePreciosForm">
		  <div class="control-group">
		  	<table class="table table-striped">
              <thead>
                <tr>
                  <th>#</th>
                  <th>Codigo Rodamiento</th>
                  <th>Caracteristica</th>
                  <th>Marca</th>
                  <th>Origen</th>
                  <th>Tipo</th>
                  <th>Codigo Propietario</th>
                  <th>Precio</th>
                </tr>
              </thead>
              <tbody>
              	<% 	int contador = 0;
					if(request.getAttribute("listaDePrecios")!=null){
					ListaDePrecios listaDePrecios = (ListaDePrecios) request.getAttribute("listaDePrecios");
					for (Rodamiento rodamiento: listaDePrecios.getItemsLP()){
						contador++;	
				%>
				<tr>
				 	<td><%= contador %></td>
				    <td><%= rodamiento.getCodigoRodamiento() %></td>
					<td><%= rodamiento.getCaracteristica() %></td>
					<td><%= rodamiento.getMarca() %></td>
					<td><%= rodamiento.getOrigen() %></td>
					<td><%= rodamiento.getTipo() %></td>
					<td><%= rodamiento.getCod_propietario() %></td>
					<td><%= rodamiento.getPrecio() %></td>
				</tr>
			      <% }
      		} %>
					              
              </tbody>
            </table>
		</div>
		  </form>
	</div>

</body>
</html>